import request from '@/utils/request'
export default{
    //分页查询所有banner
    getBanners(current,pageSize){

        return request({
            //模板字符串
            url: `/educms/bannerAdmin/getBanners/${current}/${pageSize}`,
            method: 'get',
        })

    },
     //
     getBanner(bannerId){
        return request({
            //模板字符串
            url: `/educms/bannerAdmin/getBanner/${bannerId}`,
            method: 'get',
        })

    },
    //
    save(banner){
        return request({
            url: `/educms/bannerAdmin/save`,
            method: 'post',
            data: banner
        })
    },
    //
    delete(bannerId){
        return request({
            url: `/educms/bannerAdmin/delete/${bannerId}`,
            method: 'delete',
        })
    },
    
    // 
     update(banner){
         return request({
            // url: `/eduservice/teacher/updateTeacher`,
            url: "/educms/bannerAdmin/update",
            method: 'post',
            data:banner
         })

     }
    
}